﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Text;
using CoreEx.Database.Metadata;

namespace CoreEx.Database.MetaData.Implementation
{
    public class TypeMappingInfo : ITypeMappingInfo
    {        
        public Type Type { get; set; }
        public ITableInfo TableInfo { get; set; }
        
        public IDictionary<PropertyInfo, IPropertyMappingInfo> ColumnMappings { get; set;}
        

        


        public override string ToString()
        {
            if (Type != null && TableInfo != null)
                return string.Format("Type {0} => {1} table. {2}", Type.Name, TableInfo.TableName,this.GetHashCode());

            return base.ToString();

        }
    }
}
